home *** CD-ROM | disk | FTP | other *** search
- package Config;
- require Exporter;
- @ISA = (Exporter);
- @EXPORT = qw(%Config);
-
- $] == 5.001 or die sprintf
- "Perl lib version (5.001) doesn't match executable version (%.3f)\n", $];
-
- # This file was created by configpm when Perl was built. Any changes
- # made to this file will be lost the next time perl is built.
-
- ##
- ## Manually created configuration file for Macintii
- ## Configuration time: 29Jan95
- ## Configured by: Matthias Neeracher <neeri@iis.ee.ethz.ch>
- ## Target system: Apple Macintosh
- #
-
- $config_sh=<<'!END!OF!CONFIG!';
- dynamic_ext=''
- extensions='DB_File DynaLoader Fcntl GDBM_File NDBM_File POSIX SDBM_File Socket'
- static_ext='DynaLoader'
- osname='MacOS'
- osvers='7.5'
- archlib=''
- ccflags=''
- cppflags=''
- intsize='32'
- libpth=''
- sig_name=''
- so=''
- sharpbang=''
- shsharp=''
- startsh=''
- Author='neeri'
- CC68K='C'
- CCPPC='PPCC'
- CONFIG='true'
- COptions='-m -mc68020 -r'
- Date=''
- Header=''
- Id=''
- LOptions='-mf -w'
- Locker=''
- Log=''
- Mcc='C'
- PATCHLEVEL='0'
- PPCCOptions='-shared_lib_export on -opt local'
- RCSfile=''
- ROptions='-i :'
- Revision=''
- Source=''
- State=''
- afs=''
- alignbytes=''
- aphostname=''
- archlibexp=''
- archname=''
- awk='gawk'
- bash=''
- bin=''
- binexp=''
- bison='bison'
- byacc='byacc'
- byteorder='4321'
- c=''
- castflags='0'
- cat='Catenate'
- cc='C'
- cccdlflags=''
- ccdlflags=''
- cf_by=''
- cf_time=''
- chgrp=''
- chmod=''
- chown=''
- clocktype='clock_t'
- compress='Stuffit'
- contains=''
- cp='Duplicate'
- cpio=''
- cpp='C -e'
- cpp_stuff=''
- cpplast=''
- cppminus=''
- cpprun=''
- cppstdin=''
- cryptlib=''
- csh=''
- d_Gconvert='undef'
- d_access='undef'
- d_alarm='undef'
- d_archlib='undef'
- d_attrib='undef'
- d_bcmp='define'
- d_bcopy='define'
- d_bsdpgrp='undef'
- d_bzero='define'
- d_casti32='32'
- d_castneg='define'
- d_charsprf='undef'
- d_charvspr='undef'
- d_chown='undef'
- d_chroot='undef'
- d_chsize='undef'
- d_closedir='define'
- d_const='define'
- d_crypt='undef'
- d_csh='undef'
- d_cuserid='undef'
- d_dbl_dig='define'
- d_difftime='define'
- d_dirnamlen='define'
- d_dlerror='undef'
- d_dlopen='undef'
- d_dlsymun='undef'
- d_dosuid='undef'
- d_drem='undef'
- d_dup2='2'
- d_eunice='undef'
- d_fchmod='define'
- d_fchown='undef'
- d_fcntl='define'
- d_fd_macros='define'
- d_fd_set='define'
- d_fds_bits='define'
- d_fgetpos='define'
- d_flexfnam='define'
- d_flock='undef'
- d_fmod='define'
- d_fork='undef'
- d_fpathconf='undef'
- d_fsetpos='define'
- d_getgrps='undef'
- d_gethent='undef'
- d_gethname='define'
- d_getlogin='undef'
- d_getpgrp2='undef'
- d_getpgrp='undef'
- d_getppid='undef'
- d_getprior='undef'
- d_group='undef'
- d_htonl='define'
- d_index='undef'
- d_isascii='define'
- d_killpg='undef'
- d_link='undef'
- d_linuxstd='undef'
- d_locconv='undef'
- d_lockf='undef'
- d_lstat='define'
- d_mblen='undef'
- d_mbstowcs='define'
- d_mbtowc='define'
- d_memcmp='define'
- d_memcpy='define'
- d_memmove='define'
- d_memset='define'
- d_mkdir='define'
- d_mkfifo='undef'
- d_mktime='define'
- d_msg='undef'
- d_msgctl='undef'
- d_msgget='undef'
- d_msgrcv='undef'
- d_msgsnd='undef'
- d_mymalloc='undef'
- d_nice='undef'
- d_oldsock='undef'
- d_open3='3'
- d_passwd='undef'
- d_pathconf='undef'
- d_pause='undef'
- d_phostname='undef'
- d_pipe='undef'
- d_portable='undef'
- d_pwage='undef'
- d_pwchange='undef'
- d_pwclass='undef'
- d_pwcomment='undef'
- d_pwexpire='undef'
- d_pwquota='undef'
- d_readdir='define'
- d_readlink='define'
- d_rename='define'
- d_rewinddir='define'
- d_rmdir='define'
- d_safebcpy='define'
- d_safemcpy='undef'
- d_seekdir='define'
- d_select='define'
- d_sem='undef'
- d_semctl='undef'
- d_semget='undef'
- d_semop='undef'
- d_setegid='undef'
- d_seteuid='undef'
- d_setlinebuf='undef'
- d_setlocale='define'
- d_setpgid='undef'
- d_setpgrp2='2'
- d_setpgrp='undef'
- d_setprior='undef'
- d_setregid='undef'
- d_setresgid='undef'
- d_setresuid='undef'
- d_setreuid='undef'
- d_setrgid='undef'
- d_setruid='undef'
- d_setsid='undef'
- d_shm='undef'
- d_shmat='undef'
- d_shmatprototype='undef'
- d_shmctl='undef'
- d_shmdt='undef'
- d_shmget='undef'
- d_socket='define'
- d_sockpair='undef'
- d_statblks='undef'
- d_stdstdio='define'
- d_strchr='define'
- d_strcoll='undef'
- d_strctcpy='undef'
- d_strerrm='undef'
- d_strerror='define'
- d_strxfrm='define'
- d_suidsafe='undef'
- d_symlink='define'
- d_syscall='undef'
- d_sysconf='undef'
- d_sysernlst='undef'
- d_syserrlst='undef'
- d_system='undef'
- d_tcgetpgrp='undef'
- d_tcsetpgrp='undef'
- d_telldir='define'
- d_time='define'
- d_times='define'
- d_truncate='undef'
- d_tzname='undef'
- d_umask='define'
- d_uname='undef'
- d_vfork='undef'
- d_void_closedir='undef'
- d_voidsig='undef'
- d_voidtty='undef'
- d_volatile='define'
- d_vprintf='define'
- d_wait4='undef'
- d_waitpid='undef'
- d_wcstombs='define'
- d_wctomb='define'
- d_xenix='undef'
- date='Date'
- defvoidused=''
- direntrytype='dirent'
- dlext=''
- dlsrc=''
- echo='Echo'
- egrep='egrep'
- emacs='$emacs'
- eunicefix=':'
- expr='Evaluate'
- find=''
- flex='flex'
- fpostype='fpos_t'
- gcc='gcc'
- gccversion=''
- gidtype=''
- glibpth=''
- grep='grep'
- groupcat=''
- groupstype=''
- h_fcntl='true'
- h_sysfile='false'
- hint=''
- hostcat=''
- huge=''
- i_bsdioctl=''
- i_db='define'
- i_dbm='define'
- i_dirent='define'
- i_dld=''
- i_dlfcn=''
- i_fcntl='define'
- i_float='define'
- i_gdbm='undef'
- i_grp='undef'
- i_limits='define'
- i_malloc='undef'
- i_math='define'
- i_memory='define'
- i_ndbm='define'
- i_neterrno='undef'
- i_niin='undef'
- i_pwd='undef'
- i_sgtty=''
- i_stdarg='define'
- i_stddef='define'
- i_stdlib='define'
- i_string='define'
- i_sysdir='undef'
- i_sysfile='undef'
- i_sysfilio=''
- i_sysin='define'
- i_sysioctl='define'
- i_sysndir=''
- i_sysparam=''
- i_sysselct=''
- i_syssockio=''
- i_systime='define'
- i_systimek=''
- i_systimes=''
- i_termio=''
- i_termios=''
- i_time='define'
- i_unistd='define'
- i_utime=''
- i_varargs=''
- i_varhdr='stdarg.h'
- i_vfork=''
- incpath=''
- inews=''
- installarchlib=''
- installbin=''
- installmansrc=''
- installprivlib=''
- installscript=''
- known_extensions='DB_File DynaLoader Fcntl GDBM_File NDBM_File ODBM_File POSIX SDBM_File Socket'
- ksh=''
- large=''
- lddlflags=''
- ldflags=''
- less=''
- libc=''
- libs=''
- libswanted=''
- line='line'
- lint=''
- lkflags=''
- ln=''
- lns=''
- lp=''
- lpr='Print'
- ls='Directory'
- lseektype=''
- mail=''
- mailx=''
- make='BuildProgram'
- mallocobj=''
- mallocsrc=''
- malloctype=''
- manext=''
- mansrc=''
- mansrcexp=''
- medium=''
- mips=''
- mips_type=''
- mkdir='NewFolder'
- models=''
- modetype=''
- more=''
- mv='Move'
- mydomain=''
- myhostname=''
- myuname=''
- n=''
- nm_opt=''
- nroff=''
- optimize=''
- orderlib=''
- package=''
- passcat=''
- perl='Perl'
- pg=''
- phostname=''
- plibpth=''
- pmake=''
- pr=''
- prefix=''
- privlib=''
- privlibexp=''
- prototype=''
- randbits=''
- ranlib=''
- rm='Delete'
- rmail=''
- runnm=''
- scriptdir=''
- scriptdirexp=''
- sed='sed'
- selecttype=''
- sendmail=''
- sh=''
- shar=''
- shmattype=''
- signal_t='signal_t'
- sizetype=''
- sleep=''
- smail=''
- small=''
- sockethdr=''
- socketlib=''
- sort='Sort'
- spackage=''
- spitshell=''
- split=''
- ssizetype=''
- stdchar=''
- strings='define'
- submit=''
- sysman=''
- tail=''
- tar=''
- tbl=''
- test=''
- timeincl='time.h'
- timetype='time_t'
- touch='SetFile -m .'
- tr=''
- troff=''
- uidtype=''
- uname=''
- uniq=''
- usedl=''
- usemymalloc=''
- usenm=''
- useposix='true'
- usevfork=''
- usrinc=''
- uuname=''
- vi=''
- voidflags=''
- xlibpth=''
- yacc=''
- yaccflags=''
- zcat=''
- !END!OF!CONFIG!
-
-
- tie %Config, Config;
- sub TIEHASH { bless {} }
- sub FETCH {
- # check for cached value (which maybe undef so we use exists not defined)
- return $_[0]->{$_[1]} if (exists $_[0]->{$_[1]});
-
- my($value); # search for the item in the big $config_sh string
- return undef unless (($value) = $config_sh =~ m/^$_[1]='(.*)'\s*$/m);
-
- $value = undef if $value eq 'undef'; # So we can say "if $Config{'foo'}".
- $_[0]->{$_[1]} = $value; # cache it
- return $value;
- }
-
- sub FIRSTKEY {
- $prevpos = 0;
- my $key;
- ($key) = $config_sh =~ m/^(.*)=/;
- $key;
- }
-
- sub NEXTKEY {
- my ($pos, $len);
- $pos = $prevpos;
- $pos = index( $config_sh, "\n", $pos) + 1;
- $prevpos = $pos;
- $len = index( $config_sh, "=", $pos) - $pos;
- $len > 0 ? substr( $config_sh, $pos, $len) : undef;
- }
-
- sub EXISTS{
- exists($_[0]->{$_[1]}) or $config_sh =~ m/^$_[1]=/m;
- }
-
- sub readonly { die "\%Config::Config is read-only\n" }
-
- sub STORE { &readonly }
- sub DELETE{ &readonly }
- sub CLEAR { &readonly }
-
-
- 1;
-